<template>
  <div class="attr-sp">
    <div class="attr-header">
      <slot name="attrHead"></slot>
    </div>
    <div class="attr-main">
      <el-table border :data="attrSpList" style="width: 100%">
        <slot name="attr-tab"></slot>
        <el-table-column prop="price" label="销售价格" align='center' >
        </el-table-column>
        <el-table-column align='center' prop="stock" label="商品库存" >
        </el-table-column>
        <el-table-column align='center' prop="lowStock" label="库存预警值">
        </el-table-column>
        <el-table-column align='center' prop="productSku" label="SKU编号">
        </el-table-column>
        <el-table-column align='center' label="操作" width='80'>
          <template slot-scope="scope">
            <el-button type="text" size="small"
              >查看</el-button
            >
            <el-button type="text" size="small">编辑</el-button>
          </template>
        </el-table-column>
      </el-table>
    </div>
    <div class="attr-footer">
      <el-button type="primary">刷新列表</el-button>
      <el-button type="primary">同步价格</el-button>
      <el-button type="primary">同步库存</el-button>
    </div>
  </div>
</template>

<script>
export default {
  name: "AttrSp",
  props: {
    attrSpList: Array,
  },
};
</script>

<style scoped lang="less">
.attr-main{
  margin: 20px 0 40px;
}
</style>